home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat4 / cpio.z / cpio
Encoding:
Text File  |  2002-10-03  |  2.3 KB  |  67 lines

  1.  
  2.  
  3.  
  4. CCCCPPPPIIIIOOOO((((4444))))                                                                CCCCPPPPIIIIOOOO((((4444))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      cpio - format of cpio archive
  10.  
  11. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  12.      The _h_e_a_d_e_r structure, when the ----cccc option of _c_p_i_o(1) is not used, is:
  13.  
  14.           struct {
  15.                      short    h_magic,
  16.                               h_dev;
  17.                      ushort   h_ino,
  18.                               h_mode,
  19.                               h_uid,
  20.                               h_gid;
  21.                      short    h_nlink,
  22.                               h_rdev,
  23.                               h_mtime[2],
  24.                               h_namesize,
  25.                               h_filesize[2];
  26.                      char     h_name[h_namesize rounded to word];
  27.           } Hdr;
  28.  
  29.      When the ----cccc option is used, the _h_e_a_d_e_r information is described by:
  30.  
  31.        sscanf(Chdr,"%6lo%6lo%6llo%6lo%6lo%6lo%6lo%6lo%11lo%6o%11llo%s",
  32.          &Hdr.h_magic, &Hdr.h_dev, &Hdr.h_ino, &Hdr.h_mode,
  33.          &Hdr.h_uid, &Hdr.h_gid, &Hdr.h_nlink, &Hdr.h_rdev,
  34.          &Hdr.g_mtime, &Hdr.h_namesize,&Hdr.h_filesize,Hdr.h_name);
  35.     Other archive formats (e.g uuuussssttttaaaarrrr) use other sscanf strings.
  36.     The contents of each file are recorded in an element of the array of
  37.     varying length structures, _a_r_c_h_i_v_e, together with other items describing
  38.     the file.  Every instance of _h__m_a_g_i_c contains the constant 070707 (octal).
  39.     The items _h__d_e_v through _h__m_t_i_m_e have meanings explained in _s_t_a_t(2).  The
  40.     length of the null-terminated path name _h__n_a_m_e, including the null byte,
  41.     is given by _h__n_a_m_e_s_i_z_e.
  42.  
  43.      The last record of the _a_r_c_h_i_v_e always contains the name TRAILER!!!.
  44.      Special files, directories, and the trailer are recorded with _h__f_i_l_e_s_i_z_e
  45.      equal to zero.
  46.  
  47. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  48.      cpio(1), find(1), stat(2)
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.